import { createI18n } from 'vue-i18n';

// 英文语言包
const enMessages = {
  message: {
    hello: 'Hello, world!',
  },
};

// 中文语言包
const zhMessages = {
  message: {
    en: {
      translation: {
        title: 'Translation Service',
        placeholder: 'Enter text to translate...',
        resultPlaceholder: 'Translation Result',
        translateButton: 'Translate'
      }
    },
    zh: {
      translation: {
        title: '翻译服务',
        placeholder: '请输入要翻译的文本...',
        resultPlaceholder: '翻译结果',
        translateButton: '翻译'
      }
    }
  },
};

const i18n = createI18n({
  locale: 'en', // 设置默认语言
  messages: {
    en: enMessages,
    zh: zhMessages,
  },
});

export default i18n;